using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace GameForKids
{
    class BackgroundScreen : GameScreen
    {
        const string path = "Textures/Backgrounds/";
        Texture2D backgrround;
        string backgroundTexttureName;
        public BackgroundScreen(string backgroundname)
        {
            TransitionOnTime = TimeSpan.FromSeconds(0.0);
            TransitionOffTime = TimeSpan.FromSeconds(0.5);
            backgroundTexttureName = path+backgroundname;
        }
        public override void LoadContent()
        {
            backgrround = Load<Texture2D>(backgroundTexttureName);
            base.LoadContent();
        }
        public override void Draw(GameTime gameTime)
        {
            SpriteBatch spriteBatch = ScreenManager.SpriteBatch;
            spriteBatch.Begin();
            spriteBatch.Draw(backgrround, Vector2.Zero,Color.White);
            spriteBatch.End();
            base.Draw(gameTime);
        }
    }
}
